libxl: Do not trust backend for vtpm in getinfo (except uuid)
authorIan Jackson <ian.jackson@eu.citrix.com>
Fri, 29 Apr 2016 16:18:44 +0000 (17:18 +0100)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Thu, 2 Jun 2016 14:53:29 +0000 (15:53 +0100)
commit615c2be2ff0788c71bf6520abd79154f15bb5a79
treef91a586e72dac47bc3e7325b700b5af455d4f5d7
parent696a1c5e8e59a16b6047df6936444842e6408521
libxl: Do not trust backend for vtpm in getinfo (except uuid)

* Do not check the backend for existence.  We have already read the
  /libxl path so know that the vtpm exists (or is supposed to); if the
  backend doesn't exist then that must be the backend's doing.
* Get the frontend path from the /libxl directory.
* The frontend domid is the guest domid, and does not need to be read
  from xenstore (!)

We still attempt to read the uuid from the backend.  This will be
fixed in the next patch.

This is part of XSA-178.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Reviewed-by: Wei Liu <wei.liu2@citrix.com>
tools/libxl/libxl.c